$(function(){
	$('a[rel="gallery"]').fancybox({
        overlayOpacity: 0.7,
        overlayColor: '#111111',
        autoScale: false,
        onStart: function(){$.scrollTo(0, 0);}
    });
	
	$("#codedrive_license_link").fancybox({
        overlayOpacity: 0.7,
        autoScale: false,
        overlayColor: '#111111'
    });

    var url = $("#download_url").val();
    $('[id^="get_codedrive"]').click( function(){
        if (url != '')
        {
            window.location = url;
        }
    });

    $(".play_sample_button").click( function(){
        window.location = "/samples.html";
    });
});
